# 路由器


router = '{{"vpc.vrouter-{router_uuid}": {{'\
    '"Type": "ZStack::Resource::VpcVRouter",'\
    '"Properties": {{'\
        '"name": "{router_name}",'\
        '"virtualRouterOfferingUuid": "{router_offer_uuid}"'\
        '}}'\
    '}}'\
'}}'


attach_router_to_l3network = '{{"AttachL3NetworkToVm-edge{router_num}": {{'\
        '"Type": "ZStack::Action::AttachL3NetworkToVm",'\
        '"Properties": {{'\
            '"l3NetworkUuid": {{'\
                '"Fn::GetAtt": ['\
                    '"vpc.network-{vpc_uuid}",'\
                    '"uuid"'\
                    ']'\
                '}},'\
            '"vmInstanceUuid": {{'\
                '"Fn::GetAtt": ['\
                    '"vpc.vrouter-{router_uuid}","uuid"'\
                    ']'\
                '}}'\
            '}},'\
        '"DependsOn": ['\
            '"AddIpRangeByNetworkCidr-{vpc_uuid}"'\
            ']'\
        '}}'\
    '}}'

attach_router_to_l3network_vm = "AttachL3NetworkToVm-edge{router_num}"
